// 开发环境下配置插件菜单和app信息
const systemToolsRootRoute = '/faas-demo-addons'
const pluginWebAppInfos = [
  {
    menuAlias: 'faas-demo-addons',
    //menuPath: 'http://127.0.0.1:8089/plugin/faas-demo-addons/index.html',
    menuPath: 'http://127.0.0.1:8089/plugin/faas-demo-addons/',
    //menuPath: 'http://127.0.0.1:81/plugin/faas-demo-addons/',
    //menuPath: 'http://127.0.0.1:80/plugin/faas-demo-addons/',
    rootRouting: `ui${systemToolsRootRoute}`
  }
]

const navigationInfos = [
  {
    "id":1000,
    "parentId":0,
    "name":"插件示例",
    "path":"",
    "component":null,
    "visible": true,
    "keepAlive": true,
    "icon":"system",
    "children":[
      {
        "id":2000,
        "parentId":1000,
        "name":"测试用户",
        "path":`${systemToolsRootRoute}/faas-demo-user`,
        "component":"microapp/index",
        "icon":"user",
        "visible": true,
        "keepAlive": true,
        "children":null
      }]
  }
]

export const getDevApp = () => {
  return pluginWebAppInfos
}

export const getDevMenu = () => {
  return navigationInfos
}

const getProps = () => {
  const props = {}
  props.token = store.getters.token
  return props
}
